<!DOCTYPE html>
<html lang="zh">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      //   var str = prompt("你爱我吗？")
      //   while (str !== "我爱你") {
      //     str = prompt("你爱我吗？")
      //   }
      //   alert("我也爱你啊")
      do {
        var str = prompt("你爱我吗？")
      } while (str !== "我爱你")
      alert("我也爱你啊")
    </script>
  </body>
</html>
